﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Joblist.aspx.cs" Inherits="QualityRPT.Joblist" %>
<%@ Register TagPrefix="uc1" TagName="clheader" Src="include/cl_header.ascx" %>
<%@ Register TagPrefix="uc1" TagName="cltop" Src="include/cl_top.ascx" %>
<%@ Register TagPrefix="uc1" TagName="clleft" Src="include/cl_left.ascx" %>
<%@ Register TagPrefix="uc1" TagName="clfooter" Src="include/cl_footer.ascx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>ETC产品质量跟踪统计系统-任务列表</title>
    <uc1:clheader id="clheader" runat="server"/>
</head>
<!-- this is content start-->
<body>
 <uc1:cltop id="cltop" runat="server"/>
 <div class="container-fluid">
    <div class="row-fluid">
    <uc1:clleft id="clleft" runat="server"/>
    <div class="box span10">
    <div class="box-header well">
	    <h2><i class="icon-th"></i>任务列表</h2>
    </div>
    <table class="table table-striped table-bordered bootstrap-datatable datatable">
        <thead>
            <tr>
                <th style="width:10%;">任务名</th>
                <th style="width:8%;">开始时间</th>
                <th style="width:8%;">完成时间</th>
                <th style="width:8%;">数据开始时间</th>
                <th style="width:8%;">数据结束时间</th>
                <th style="width:5%;">任务类型</th>
                <th style="width:8%;">任务状态</th>
                <th style="width:15%;">详情</th>
                <th style="width:8%;">用户</th>
                <th style="width:5%;">操作</th>
            </tr>
        </thead>
        <tbody>
        <asp:Repeater ID="repeater_joblist" runat="server">
        <ItemTemplate>
            <tr>
                <td><%# DataBinder.Eval(Container.DataItem, "JOB_NAME")%></td>
                <td><%# DataBinder.Eval(Container.DataItem, "JOB_START_TIME","{0:yyyy-MM-dd HH:mm}")%></td>
                <td><%# DataBinder.Eval(Container.DataItem, "JOB_END_TIME","{0:yyyy-MM-dd HH:mm}")%></td>
                <td><%# DataBinder.Eval(Container.DataItem, "DATA_START_TIME","{0:yyyy-MM-dd HH:mm}")%></td>
                <td><%# DataBinder.Eval(Container.DataItem, "DATA_END_TIME","{0:yyyy-MM-dd HH:mm}")%></td>
                <td><%#GetJobType(DataBinder.Eval(Container.DataItem, "JOB_TYPE"))%></td>
                <td><%#GetStatus(DataBinder.Eval(Container.DataItem, "DATA_STATUS"))%></td>
                <td><%# DataBinder.Eval(Container.DataItem, "NOTE")%></td>
                <td><%#GetJobUserName(DataBinder.Eval(Container.DataItem, "USER_ID"))  %></td>
                <td>
                    <%#GetPauseLink(DataBinder.Eval(Container.DataItem, "DATA_STATUS"),DataBinder.Eval(Container.DataItem, "ID"))%>
                    <span style="<%#GetRsStyle(DataBinder.Eval(Container.DataItem, "JOB_TYPE"),DataBinder.Eval(Container.DataItem, "DATA_STATUS"))%>">
                    <a href="StatJobResult.aspx?id=<%# DataBinder.Eval(Container.DataItem, "ID")%>&pid=<%=Request.Params["pid"] %>&cid=<%=Request.Params["cid"] %>" target="_blank">显示结果</a>
                    <a href="StatJobResult.aspx?id=<%# DataBinder.Eval(Container.DataItem, "ID")%>&pid=<%=Request.Params["pid"] %>&cid=<%=Request.Params["cid"] %>&export=1">导出Excel</a>
                    </span>
                </td>
            </tr>
        </ItemTemplate>
        </asp:Repeater>
        </tbody>
    </table>
   <div class="pager"><%=PagerHtml %></div>
</div>
</div>		
<!-- content end-->
</div>
<uc1:clfooter id="clfooter" runat="server"/>
</body>
</html>
